<?php
/**
 * Created by PhpStorm.
 * User: zhouke
 * Date: 2018-09-12
 * Time: 15:48
 */

defined('BASEPATH') OR exit('No direct script access allowed');
class Base_admin extends CI_Controller {
    var $login_user, $after_login_url, $is_no_need_mobile_bind;
    function __construct() {
        parent::__construct();
    }
    function check_login( $jumpto = '' ) {
        $this->login_user = user_login_get();
        $jumpto = $jumpto == '' ? site_url($this->uri->uri_string) : $jumpto;
        if( $this->login_user['is_admin'] == 1 ) {

        } else {
            user_logout();
            my_redirect('', site_url('admin/passport/index').'?ref='.urlencode($jumpto), FALSE);
        }
    }
}